<template>
    <div class="component-configFilterTable h-100 w-100">
        <div class="card_shadow p-8 mb-10"  v-if="showFormFilter">

            <com-form
                v-if="showFormFilter"
                ref="filterForm"
                 class="pt-16"
                :busCode="busCode"
                :initFormData="initFormData"
                :configs="computedFilterFormConfig"
                :inline="filterInline"
                :label-width="filterLabelWidth"
                :col="filterCol"
                :label-position="labelPosition"
                :wrappers="computedWrappers"
                @changeOut="$emit('filter-changeOut', $event)"
            >
                <!-- <div
                    v-if="showSearch && topRightOperationLine"
                    slot="inline"
                    class="d-inline-block line-height-40"
                >
                    <el-button
                        type="primary"
                        size="mini"
                        @click="operationHandle({ handle: 'query' })"
                    >
                        {{ filterFormConfig ? "查询" : "刷新" }}
                    </el-button>
                    <el-button
                        v-if="filterFormConfig"
                        size="mini"
                        @click="operationHandle({ handle: 'resetFilterForm' })"
                    >
                        重置
                    </el-button>
                    <slot name="topRightOperation"></slot>
                </div> -->
            </com-form>
             <!-- <div class="title_wrap" v-if="closeNumber || closeNumber === 0">
                <div class="flex-1 action_wrap">
                    <div
                        class="coll_control mx-12"
                        v-if="closeNumber || closeNumber === 0"
                        @click="(v) => (showColl = !showColl)"
                    >
                        {{ showColl ? "收起" : "展开" }}
                        <i
                            class="el-icon-d-arrow-right"
                            :class="showColl ? 'rotate-270' : 'rotate-90'"
                        ></i>
                    </div>
                </div>
            </div> -->
        </div>

        <div class="card_shadow p-8 mb-10">
            <div
                v-if="!(!hasTopOperationLeft && topRightOperationLine)"
                class="top-opertaions-container flex-ju-between"
            >
                <div class="left-operations-container d-block">
                    <template v-if="hasTopOperationLeft">
                        <el-button
                            size="mini"
                            style="margin-bottom: 8px"
                            v-for="operation in topOperation.left"
                            :key="operation.key"
                            :type="operation.type"
                            :icon="operation.icon"
                            :disabled="operation.disabled"
                            v-permission="permission(operation)"
                            @click="operationHandle(operation)"
                        >
                            {{ operation.name }}
                        </el-button>
                    </template>
                    &nbsp;
                </div>
            </div>
            <!-- 需要添加的其他信息 比如tab -->
            <slot></slot>
            <div  class="card_shadow">
                <div v-if="showRequestNum" class="tip-container radius-4 mb-12">
                <i class="el-icon-info tip-icon color-blue" />
                <span class="tip-text">
                    共查询到 {{ tableData.total || "-" }} 条数据
                    <span v-if="hasSelection"
                        >，已选择
                        <span class="color-blue">{{
                            selectionList.length
                        }}</span>
                        条数据
                    </span>
                </span>
            </div>
           
            <com-table
                ref="table"
                :busCode="busCode"
                :table-column="tableColumn"
                :param="filteData"
                :tableTitle='tableTitle'
                :services="services"
                :data-format-handle="dataFormatHandle"
                :pagination="pagination"
                :issummary='issummary'
                :pageSizes="pageSizes" 
                :highlight-current-row="highlightCurrentRow"
                :row-class-name="rowClassName"
                :span-method="spanMethod"
                :border="tableBorder"
                :import-data="importData"
                :height="height"
                :maxHeight="maxHeight"
                :auto-load="false"
                :isSingleSelect="isSingleSelect"
                :dataType="dataType"
                :tableNoWrap="tableNoWrap"
                v-bind="{
                    ...$attrs,
                    ...tableProps
                }"
                @select-all="selectAll"
                @select="selectHandle"
                @selected-change="tableSelectionChangeHandle"
                @data-change="tableDataChange"
                @current-change="tableCurrentChangeHandle"
                v-on="$listeners"
            />
        </div>
            </div>
    </div>
</template>
<style scoped lang="scss" src="./com-filterTable.scss"></style>
<script src="./com-filterTable.js"></script>
<style lang="scss">
.component-configFilterTable {
    .el-table th.gutter {
        display: table-cell !important;
    }
}
</style>
